import { createApp } from "vue";
import pinia from "@/stores"

import App from "./App.vue";
import router from "./router";
//SVG图标库
// import "//at.alicdn.com/t/c/font_3687494_zbzwv6wusm.js" 转至HTML页面
import { setupSvgIcon } from './plugin/SvgIcon/index'
//全局组件
import TiebaTitle from '@/components/TiebaTitle.vue'
import TiebaComment from '@/components/TiebaComment.vue'

//elementPlus
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'

//permission
import "@/utils/permission"

import '@/style/skeleton.scss'
import {initInject} from '@/inject'

const app = createApp(App)
//全局组件
app.component('TiebaTitle', TiebaTitle)
app.component('TiebaComment', TiebaComment)

setupSvgIcon(app)
app.use(ElementPlus)
app.use(pinia)
app.use(router)


app.mount('#app')

if (import.meta.env.DEV) {
    setTimeout(initInject)
  }
